
<include file="Public:header" />
<style>
.viewEditBox8749{display:none;}

input,textarea{border:1px solid #ccc; border-radius:2px; box-shadow:0 1px 5px #ccc inset; text-indent:0.5em;}
input{height:35px; line-height:1;}
</style>
<script src="__PUBLIC__/Js/validform/Validform.js"></script>
<link rel="stylesheet" type="text/css" href="__PUBLIC__/Js/validform/style.css">
<script>
	$(document).ready(function(e) {
        $.ajax({
			url:"{:U('Ajax/getRegion')}",
			data:"",
			type:"POST",
			dataType:"html",
			success: function(data){
				$('#areabox').html(data);
			}
		}); 
    });
	function removnextAll(e){
		if($(e).next().length>0){
			removnextAll($(e).next());
			$(e).next().remove();
		}
	}
	function sendRegion(e){
		if(e.value>0){
			$.ajax({
			url:"{:U('Ajax/getRegion')}",
			data:"fid="+e.value,
			type:"POST",
			dataType:"html",
				success: function(data){
					removnextAll(e);
					$(e).parent().append(data);
				}
		    });
	    }else{
		    removnextAll(e);
	    }
	    return false;
	}
</script>
<body>




<div style="padding:0.5px;"><table width="100%" border="1" bordercolor="#C8C8C8" cellpadding="0" cellspacing="0">
  <tbody>
    <tr align="center">
      
      <th align="center">商品图</th>
      <th align="center">基本信息</th>
    </tr>
    
    <?php foreach($productList as $key => $vo){?>
    
    <tr>
     
      <td align="center"><img src="__PUBLIC__<?php echo $vo['img_url'];?>" width="100"></td>
      <td align="left" style="padding:0.5em;">
      名称：<?php echo $vo['title'];?>
      数量：<?php echo $vo['num'];?></td>
      
    
    <?php }?>
    <tr>
      <td colspan="2" align="right" class="indBtn"><span style="font-size:20px;">总计：</span><span style="color:#f00; font-size:20px;">¥<span id="_total"><?php echo $total;?></span></span></td>
      </tr>
  </tbody>
</table>


<form class="checkoutform" action="<?php echo U('createOrder');?>" method="post">

<table width="100%" border="1" cellpadding="0" bordercolor="#B8B8B8" cellspacing="0">
  <tbody>
    <tr>
      <th colspan="2" align="left">填写订单信息</th>
      </tr>
    <tr>
      
      <td><input datatype="*" style="width:100%" placeholder="收货人" errormsg="请填写收货人！" name="yourname" type="text" id="yourname"></td>
    </tr>
    <tr>
      
      <td><span id="areabox">
</span></td>
    </tr>
    <tr>
     
      <td><textarea placeholder="街道地址" name="address" rows="6" style="width:100%" id="address" datatype="*" errormsg="请填写详细地址"></textarea></td>
    </tr>
    <tr>
     
      <td><input datatype="m" placeholder="手机" style="width:100%" errormsg="请填写正确格式的手机号码" name="tel" type="text" id="tel"><span class="Validform_checktip"></td>
    </tr>
    <tr>
      <td colspan="2" align="center" class="indBtn"><input style="border:none; background:#2374A8; color:#fff; padding:10px 20px; font-size:16px;" type="submit" name="button" id="button" value="提交订单"></td>
    </tr>
    </tbody>
</table>

</form>



</div>
<style>

table{margin-top:10px !important;}
td,th{padding:5px 12px !important;}
#areabox select{margin:5px;}
</style>


<script type="text/javascript">
$(function(){
	//$(".registerform").Validform();  //就这一行代码！;
	
	$(".checkoutform").Validform({
		tiptype:1
	});
})
</script>



<include file="Public:footer" />


